import { createApp, ref } from 'vue'
import App from './App.vue'
import './styles/reset.scss'
import './styles/index.scss'
import ElementPlus from 'element-plus'
import 'element-plus/dist/index.css'
import router from './router'

// function useTheme() {
//   const themeLink = ref<HTMLLinkElement | null>(null)
//   console.log('theme link', themeLink)
//   const switchTheme = (themeType: string) => {
//     if (themeLink.value) {
//       if (themeType === 'dark') {
//         themeLink.value.href = './styles/index.scss'
//       } else {
//         themeLink.value.href = './styles/index.scss'
//       }
//     }
//   }
//   return {
//     themeLink,
//     switchTheme,
//   }
// }

const app = createApp(App)
app.use(ElementPlus, { size: 'small' })
app.use(router)
app.mount('#app')
